package com.ytjj.qmyx.supplychain.common.enums;

/**
 * @Description 后台管理员账号状态
 * @ClassName AdminStatusEnums
 * 
 * 
 * @Version 1.0
 **/
public enum StockWarnStatusEnums {
    /**
     * 报警状态: 1.预警中 2.预警结束 3.预警失效)
     */
    ING(1, "预警中"),
    END(2, "预警结束"),
    LOSE(3, "预警失效");
    /**
     * 状态
     */
    private Integer status;
    /**
     * 状态描述
     */
    private String statusDesc;

    StockWarnStatusEnums(Integer status, String statusDesc) {
        this.status = status;
        this.statusDesc = statusDesc;
    }

    public Integer getStatus() {
        return status;
    }

    public String getStatusDesc() {
        return statusDesc;
    }

    public static String getStatusDesc(Integer status) {
        StockWarnStatusEnums[] values = StockWarnStatusEnums.values();
        for (StockWarnStatusEnums value : values) {
            if(value.status.equals(status)) {
                return value.statusDesc;
            }
        }
        return null;
    }
}
